﻿namespace PowerSong.SongDatabase
    {
    using System;

    public class DatabaseIsLegacyExportFileException : ApplicationException
        {

        public DatabaseIsLegacyExportFileException()
            : base("The database is not a valid PowerSong 2 database because it is actually a legacy GZIP-based PowerSong export file.")
            {
            }

        }

    public class IncompatibleDatabaseException : ApplicationException
        {

        public IncompatibleDatabaseException()
            : base("The database is incompatible with this version of PowerSong.")
            {
            }

        }

    public class SchemaVersionException : Exception
        {

        public SchemaVersionException(FileEntryType fileEntryType, int actualVersionNumber)
            : base("Cannot read in an object of type " + fileEntryType + " from the database because it's schema version (" + actualVersionNumber + ") cannot be read by this version of PowerSong.")
            {
            }

        }

    }
